home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 26 / AACD 26.iso / AACD / Programming / ace_gpl_release / src / lib / asm / logic.s < prev    next >
Encoding:
Text File  |  1998-10-04  |  1.7 KB  |  74 lines

  1. ;
  2. ; logic.s -- an ACE linked library object file: logic functions.
  3. ; Copyright (C) 1998 David Benn
  4. ; This program is free software; you can redistribute it and/or
  5. ; modify it under the terms of the GNU General Public License
  6. ; as published by the Free Software Foundation; either version 2
  7. ; of the License, or (at your option) any later version.
  8. ;
  9. ; This program is distributed in the hope that it will be useful,
  10. ; but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  12. ; GNU General Public License for more details.
  13. ;
  14. ; You should have received a copy of the GNU General Public License
  15. ; along with this program; if not, write to the Free Software
  16. ; Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
  17. ;
  18. ; Author: David J Benn
  19. ;   Date: 3rd-30th November, 1st-13th December 1991,
  20. ;      20th, 23rd,25th-27th January 1992, 
  21. ;         2nd,4th,6th,12th-19th,21st-24th,29th February 1992,
  22. ;      1st,14th March 1992,
  23. ;      4th,7th,21st,22nd,26th April 1992,
  24. ;      2nd,3rd,5th,7th,8th,10th-17th May 1992,
  25. ;      6th,8th,11th,12th,28th,30th June 1992,
  26. ;      1st-3rd,13th,14th,18th-20th,22nd July 1992,
  27. ;      9th August 1992,
  28. ;      5th,8th December 1992
  29. ;
  30. ; a4,a5 are used by link/unlk.
  31. ; a6 is library base holder.
  32. ; a7 is stack pointer. 
  33. ; d7 is used for array index calculations.
  34. ;
  35.  
  36.     ; logic functions
  37.     xdef    _impw
  38.     xdef    _impl
  39.     xdef    _eqvw
  40.     xdef    _eqvl
  41.  
  42.     SECTION logic_code,CODE
  43.  
  44. ;*** LOGIC OPERATORS ***
  45.    
  46. ;
  47. ; logical operator IMP: d0 = d1 imp d0
  48. ;
  49. _impw:
  50.        not.w d1
  51.           or.w  d1,d0
  52.         rts
  53.  
  54. _impl:
  55.           not.l d1
  56.           or.l  d1,d0
  57.         rts
  58.  
  59. ;
  60. ; logical operator EQV: d0 = d1 eqv d0
  61. ;
  62. _eqvw:
  63.         eor.w d1,d0
  64.       not.w d0
  65.       rts
  66.  
  67. _eqvl:
  68.       eor.l d1,d0
  69.       not.l d0
  70.       rts
  71.  
  72.     END
  73.